﻿Public Class ucNotificationSound
	Public Sub New()
		InitializeComponent()

		cmbSystemSound.Items.Add("Asterisk")
		cmbSystemSound.Items.Add("Beep")
		cmbSystemSound.Items.Add("Exclamation")
		cmbSystemSound.Items.Add("Hand")
		cmbSystemSound.Items.Add("Question")
	End Sub

	Private Sub dlgSelectSoundFile_FileOk(ByVal sender As System.Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles dlgSelectSoundFile.FileOk
		txtSoundFile.Text = dlgSelectSoundFile.FileName
	End Sub

	Private Sub btnSelectSoundFile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSelectSoundFile.Click
		dlgSelectSoundFile.FileName = txtSoundFile.Text.Trim()
		dlgSelectSoundFile.ShowDialog(Me)
	End Sub

	Private Sub btnPlay_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPreview.Click
		If DataSource Is Nothing Then Exit Sub
		DataSource.PlaySound()
	End Sub
End Class
